package a.j;

import a.c.d;
import a.c.e;
import a.c.m;
import a.c.q;
import a.c.w;
import a.j.a.j;

import java.awt.*;
import java.awt.geom.Rectangle2D;
import java.util.ArrayList;
import java.util.Iterator;

public class mb
  implements vd
{
  private final c_ a = new c_();
  private final c_ b = new c_();
  private int c = 10;
  private gb d;
  public static boolean e;
  
  public jc a()
  {
    return this.a;
  }
  
  public jc b()
  {
    return this.b;
  }
  
  public boolean c()
  {
    return this.a.a();
  }
  
  public void a(boolean paramBoolean)
  {
    this.a.a(paramBoolean);
    this.b.a(paramBoolean);
  }
  
  public void b(boolean paramBoolean)
  {
    this.a.c(paramBoolean);
  }
  
  public boolean d()
  {
    return this.a.c();
  }
  
  public gb e()
  {
    return this.d;
  }
  
  public void a(gb paramgb)
  {
    this.d = paramgb;
  }
  
  public void c(boolean paramBoolean)
  {
    this.a.d(paramBoolean);
    this.b.d(paramBoolean);
  }
  
  public boolean f()
  {
    return this.a.e();
  }
  
  public void d(boolean paramBoolean)
  {
    this.a.e(paramBoolean);
    this.b.e(paramBoolean);
  }
  
  public boolean g()
  {
    return this.a.f();
  }
  
  public void a(int paramInt)
  {
    this.c = paramInt;
  }
  
  public int h()
  {
    return this.c;
  }
  
  public void e(boolean paramBoolean)
  {
    this.b.b(paramBoolean);
  }
  
  public boolean i()
  {
    return this.b.b();
  }
  
  public void a(Graphics2D paramGraphics2D, g paramg)
  {
    boolean bool = ld.E;
    Object localObject = null;
    Rectangle localRectangle = paramGraphics2D.getClipBounds();
    if (!bool)
    {
      if (localRectangle == null) {
        localRectangle = paramg.d();
      }
      localRectangle.x -= this.c;
      localRectangle.y -= this.c;
      localRectangle.width += 2 * this.c;
    }
    localRectangle.height += 2 * this.c;
    gb localgb = this.d;
    if (!bool)
    {
      if (localgb != null) {
        a(localgb, paramg, localRectangle);
      }
    }
    else
    {
      localObject = paramGraphics2D.getRenderingHint(d_.a);
      paramGraphics2D.setRenderingHint(d_.a, d_.a(paramg, localgb));
    }
    a(paramg, paramGraphics2D, localRectangle, false);
    if (localgb != null) {
      paramGraphics2D.setRenderingHint(d_.a, localObject);
    }
  }
  
  private void a(g paramg, Graphics2D paramGraphics2D, Rectangle paramRectangle, boolean paramBoolean)
  {
    boolean bool2 = ld.E;
    boolean bool1 = ld.D;
    Object localObject2;
    if (!bool2) {
      if (!c())
      {
        if (paramBoolean)
        {
          localIterator = this.b.a(paramg, 3);
          label113:
          label118:
          do
          {
            do
            {
              do
              {
                do
                {
                  if (!localIterator.hasNext()) {
                    return;
                  }
                  localObject1 = localIterator.next();
                  if (bool2) {
                    break label118;
                  }
                  if (!(localObject1 instanceof d)) {
                    break label113;
                  }
                  localObject2 = paramg.t((d)localObject1);
                  if (bool2) {
                    break;
                  }
                } while (!a((tb)localObject2, paramRectangle));
                b(paramGraphics2D, (tb)localObject2);
              } while ((!bool2) && ((!bool1) || (!(localObject1 instanceof e))));
              localObject2 = paramg.w((e)localObject1);
              if (bool2) {
                break;
              }
            } while (!a((ld)localObject2, paramRectangle));
            if (bool2) {
              break;
            }
            b(paramGraphics2D, (ld)localObject2);
          } while (!bool1);
        }
        Iterator localIterator = this.a.a(paramg, 3);
        label250:
        label255:
        do
        {
          do
          {
            do
            {
              do
              {
                if (!localIterator.hasNext()) {
                  return;
                }
                localObject1 = localIterator.next();
                if (bool2) {
                  break label255;
                }
                if (!(localObject1 instanceof d)) {
                  break label250;
                }
                localObject2 = paramg.t((d)localObject1);
                if (bool2) {
                  break;
                }
              } while (!a((tb)localObject2, paramRectangle));
              a(paramGraphics2D, (tb)localObject2);
            } while ((!bool2) && ((!bool1) || (!(localObject1 instanceof e))));
            localObject2 = paramg.w((e)localObject1);
            if (bool2) {
              break;
            }
          } while (!a((ld)localObject2, paramRectangle));
          a(paramGraphics2D, (ld)localObject2);
        } while ((!bool2) && (!bool1));
      }
    }
    Object localObject3;
    Object localObject4;
    int j;
    if (!bool2) {
      if (paramBoolean)
      {
        i = -1;
        localObject1 = this.b.a(paramg, 3);
        label460:
        do
        {
          do
          {
            do
            {
              do
              {
                do
                {
                  if (!((Iterator)localObject1).hasNext()) {
                    break label571;
                  }
                  localObject2 = ((Iterator)localObject1).next();
                  if (bool2) {
                    break label460;
                  }
                  if (!(localObject2 instanceof d)) {
                    break;
                  }
                  localObject3 = (d)localObject2;
                  localObject4 = paramg.t((d)localObject3);
                } while ((!bool2) && (!a((tb)localObject4, paramRectangle)));
                j = a(paramg, (d)localObject3);
                if (!bool2)
                {
                  if (j != i)
                  {
                    if (i > -1) {
                      b(paramGraphics2D, i, paramBoolean);
                    }
                    a(paramGraphics2D, j, paramBoolean);
                  }
                  b(paramGraphics2D, j, (tb)localObject4);
                  i = j;
                }
              } while ((!bool2) && ((!bool1) || (!(localObject2 instanceof e))));
              localObject3 = (e)localObject2;
              localObject4 = paramg.w((e)localObject3);
              if ((bool2) || (bool2)) {
                break label574;
              }
              if (bool1) {
                break label573;
              }
            } while (!a((ld)localObject4, paramRectangle));
            j = a(paramg, (e)localObject3);
            if (!bool2)
            {
              if (j != i)
              {
                if (i > -1) {
                  b(paramGraphics2D, i, paramBoolean);
                }
                a(paramGraphics2D, j, paramBoolean);
              }
              b(paramGraphics2D, j, (ld)localObject4);
              i = j;
            }
          } while (bool2);
        } while (!bool1);
        label571:
        label573:
        if (i <= -1) {
          label574:
          return;
        }
        b(paramGraphics2D, i, paramBoolean);
        if ((!bool2) && (!bool1)) {
          return;
        }
      }
    }
    int i = -1;
    Object localObject1 = this.a.a(paramg, 3);
    label745:
    do
    {
      do
      {
        do
        {
          do
          {
            do
            {
              if (!((Iterator)localObject1).hasNext()) {
                break label856;
              }
              localObject2 = ((Iterator)localObject1).next();
              if (bool2) {
                break label745;
              }
              if (!(localObject2 instanceof d)) {
                break;
              }
              localObject3 = (d)localObject2;
              localObject4 = paramg.t((d)localObject3);
            } while ((!bool2) && (!a((tb)localObject4, paramRectangle)));
            j = a(paramg, (d)localObject3);
            if (!bool2)
            {
              if (j != i)
              {
                if (i > -1) {
                  b(paramGraphics2D, i, paramBoolean);
                }
                a(paramGraphics2D, j, paramBoolean);
              }
              a(paramGraphics2D, j, (tb)localObject4);
              i = j;
            }
          } while ((!bool2) && ((!bool1) || (!(localObject2 instanceof e))));
          localObject3 = (e)localObject2;
          localObject4 = paramg.w((e)localObject3);
          if ((bool2) || (bool2)) {
            break label859;
          }
          if (bool1) {
            break label858;
          }
        } while (!a((ld)localObject4, paramRectangle));
        j = a(paramg, (e)localObject3);
        if (!bool2)
        {
          if (j != i)
          {
            if (i > -1) {
              b(paramGraphics2D, i, paramBoolean);
            }
            a(paramGraphics2D, j, paramBoolean);
          }
          a(paramGraphics2D, j, (ld)localObject4);
          i = j;
        }
      } while (bool2);
    } while (!bool1);
    label856:
    label858:
    if (i > -1) {
      label859:
      b(paramGraphics2D, i, paramBoolean);
    }
  }
  
  protected void a(Graphics2D paramGraphics2D, int paramInt, boolean paramBoolean) {}
  
  protected void b(Graphics2D paramGraphics2D, int paramInt, boolean paramBoolean) {}
  
  protected void a(Graphics2D paramGraphics2D, int paramInt, ld paramld)
  {
    a(paramGraphics2D, paramld);
  }
  
  protected void a(Graphics2D paramGraphics2D, int paramInt, tb paramtb)
  {
    a(paramGraphics2D, paramtb);
  }
  
  protected void b(Graphics2D paramGraphics2D, int paramInt, ld paramld)
  {
    b(paramGraphics2D, paramld);
  }
  
  protected void b(Graphics2D paramGraphics2D, int paramInt, tb paramtb)
  {
    b(paramGraphics2D, paramtb);
  }
  
  protected int a(g paramg, d paramd)
  {
    return Math.max(a(paramg, paramd.e()), a(paramg, paramd.f()));
  }
  
  protected int a(g paramg, e parame)
  {
    boolean bool2 = ld.E;
    boolean bool1 = ld.D;
    j localj = paramg.K();
    int i = 0;
    if (localj != null)
    {
      label65:
      do
      {
        if (parame == null) {
          break;
        }
        e locale = localj.p(parame);
        if (!bool2) {
          if (locale != null)
          {
            if (bool2) {
              break label65;
            }
            if (locale.g() != parame.g()) {
              return i;
            }
          }
        }
        parame = locale;
        i++;
      } while (!bool1);
      return i;
    }
    return i;
  }
  
  protected void a(gb paramgb, g paramg, Rectangle2D paramRectangle2D)
  {
    boolean bool2 = ld.E;
    boolean bool1 = ld.D;
    paramgb.a();
    paramgb.a(paramRectangle2D.getMinX() - this.c, paramRectangle2D.getMinY() - this.c, paramRectangle2D.getMaxX() + this.c, paramRectangle2D.getMaxY() + this.c);
    if (paramgb.b() != 0)
    {
      m localm = paramg.w();
      do
      {
        if (!localm.e()) {
          break;
        }
        d locald = localm.a();
        tb localtb = paramg.t(locald);
        if (!bool2)
        {
          if (a(localtb, paramRectangle2D)) {
            localtb.a(paramgb);
          }
          localm.f();
        }
      } while (!bool1);
    }
  }
  
  public static gb a(tb paramtb, Graphics2D paramGraphics2D)
  {
    boolean bool = ld.E;
    if (((bool) || (paramtb != null)) && ((bool) || (paramtb.i() != null)))
    {
      mb.d_.a_ locala_ = (mb.d_.a_)paramGraphics2D.getRenderingHint(d_.a);
      if (((bool) || (locala_ != null)) && ((bool) || (locala_.a() == paramtb.i().c()))) {
        return locala_.b();
      }
    }
    return null;
  }
  
  public void f(boolean paramBoolean)
  {
    this.b.c(paramBoolean);
  }
  
  public boolean j()
  {
    return this.b.c();
  }
  
  protected boolean a(ld paramld, Rectangle2D paramRectangle2D)
  {
    Rectangle2D.Double localDouble = hb.a().j;
    localDouble.width = (localDouble.height = -1.0D);
    paramld.b(localDouble);
    return localDouble.intersects(paramRectangle2D.getX(), paramRectangle2D.getY(), paramRectangle2D.getWidth(), paramRectangle2D.getHeight());
  }
  
  protected boolean a(tb paramtb, Rectangle2D paramRectangle2D)
  {
    return paramtb.b(paramRectangle2D);
  }
  
  public void b(Graphics2D paramGraphics2D, g paramg)
  {
    Rectangle localRectangle = paramGraphics2D.getClipBounds();
    if (!ld.E)
    {
      if (localRectangle == null) {
        localRectangle = paramg.d();
      }
      localRectangle.x -= this.c;
      localRectangle.y -= this.c;
      localRectangle.width += 2 * this.c;
    }
    localRectangle.height += 2 * this.c;
    a(paramg, paramGraphics2D, localRectangle, true);
  }
  
  protected void a(Graphics2D paramGraphics2D, ld paramld)
  {
    paramld.e(paramGraphics2D);
  }
  
  protected void a(Graphics2D paramGraphics2D, tb paramtb)
  {
    paramtb.c(paramGraphics2D);
  }
  
  protected void b(Graphics2D paramGraphics2D, ld paramld)
  {
    paramld.c(paramGraphics2D);
  }
  
  protected void b(Graphics2D paramGraphics2D, tb paramtb)
  {
    paramtb.a(paramGraphics2D);
  }
  
  static final class d_
    extends RenderingHints.Key
  {
    public static final RenderingHints.Key a = new d_();
    
    protected d_()
    {
      super();
    }
    
    public boolean isCompatibleValue(Object paramObject)
    {
      if (!ld.E) {}
      return ((paramObject instanceof a_)) || (paramObject == null);
    }
    
    public static Object a(g paramg, gb paramgb)
    {
      return new a_(paramg, paramgb);
    }
    
    static final class a_
    {
      private final g a;
      private final gb b;
      
      public a_(g paramg, gb paramgb)
      {
        this.a = paramg;
        this.b = paramgb;
      }
      
      public g a()
      {
        return this.a;
      }
      
      public gb b()
      {
        return this.b;
      }
    }
  }
  
  private final class b_
    implements jc
  {
    boolean i;
    
    private b_() {}
    
    public Iterator a(g paramg, int paramInt)
    {
      rc.e_ locale_ = new rc.e_(a(paramg, paramInt));
      if ((paramInt & 0x7C) != 0) {
        return new rc.h_(paramg, locale_, paramInt, true);
      }
      return locale_;
    }
    
    public Iterator b(g paramg, int paramInt)
    {
      rc.d_ locald_ = new rc.d_(a(paramg, paramInt));
      if ((paramInt & 0x7C) != 0) {
        return new rc.h_(paramg, locald_, paramInt, false);
      }
      return locald_;
    }
    
    private ArrayList a(q paramq, int paramInt)
    {
      boolean bool = ld.E;
      if (!bool) {}
      if (!bool) {}
      return a(paramq, (paramInt & 0x51) != 0, (paramInt & 0x2E) != 0);
    }
    
    private ArrayList a(q paramq, boolean paramBoolean1, boolean paramBoolean2)
    {
      boolean bool2 = ld.E;
      boolean bool1 = ld.D;
      ArrayList localArrayList = new ArrayList(Math.min(250, paramq.l() + paramq.j()));
      if (!bool2)
      {
        if (paramBoolean2)
        {
          if (bool2) {
            break label112;
          }
          if (this.i)
          {
            localObject1 = paramq.w();
            do
            {
              if (!((m)localObject1).e()) {
                break;
              }
              localArrayList.add(((m)localObject1).a());
              ((m)localObject1).f();
              if (bool2) {
                break label224;
              }
              if (bool1) {
                break label218;
              }
            } while (!bool1);
          }
        }
        if (bool2) {
          break label224;
        }
      }
      label112:
      Object localObject2;
      if (!bool2)
      {
        if (paramBoolean1)
        {
          localObject1 = j.a(paramq);
          if ((bool2) || (localObject1 != null))
          {
            ((j)localObject1).a(((j)localObject1).f(paramq), new mb.0(this, localArrayList));
            if (bool2) {
              break label224;
            }
            if (!bool1) {}
          }
          else
          {
            localObject2 = paramq.v();
            do
            {
              if (!((w)localObject2).e()) {
                break;
              }
              localArrayList.add(((w)localObject2).d());
              ((w)localObject2).f();
              if ((!bool2) && (bool1)) {
                break label285;
              }
            } while (!bool1);
          }
        }
        label218:
        if (bool2) {
          break label285;
        }
      }
      label224:
      if ((bool2) || ((paramBoolean2) && (!this.i)))
      {
        localObject1 = paramq.w();
        do
        {
          if (!((m)localObject1).e()) {
            break;
          }
          if (bool1) {
            break label297;
          }
          localArrayList.add(((m)localObject1).a());
          ((m)localObject1).f();
        } while (!bool1);
      }
      label285:
      label297:
      Object localObject1 = new ArrayList(localArrayList.size());
      if ((bool2) || ((!localArrayList.isEmpty()) && ((paramq instanceof g))))
      {
        localObject2 = a(localArrayList, (g)paramq);
        int j = 0;
        label415:
        label417:
        do
        {
          if (j >= localObject2.length) {
            break;
          }
          Object localObject3 = localObject2[j];
          if (bool1) {
            break label422;
          }
          if (localObject3 != null)
          {
            int k = 0;
            int m = localObject3.size();
            do
            {
              if (k >= m) {
                break;
              }
              ((ArrayList)localObject1).add(localObject3.get(k));
              k++;
              if (bool2) {
                break label417;
              }
              if (bool1) {
                break label415;
              }
            } while (!bool1);
          }
          if (!bool2) {
            j++;
          }
        } while (!bool1);
      }
      label422:
      return localObject1;
    }
    
    private ArrayList[] a(ArrayList paramArrayList, g paramg)
    {
      boolean bool2 = ld.E;
      boolean bool1 = ld.D;
      int j = 0;
      Object localObject1 = new ArrayList[10];
      int k = 0;
      int m = paramArrayList.size();
      label110:
      do
      {
        if (k >= m) {
          break;
        }
        Object localObject2 = paramArrayList.get(k);
        if (bool2) {
          break label203;
        }
        if (bool1) {
          break label198;
        }
        int n;
        if ((localObject2 instanceof e))
        {
          n = mb.this.a(paramg, (e)localObject2);
          if (bool2) {
            break label110;
          }
          if (!bool1) {}
        }
        else
        {
          n = mb.this.a(paramg, (d)localObject2);
        }
        j = Math.max(n, j);
        if ((bool2) || (n >= localObject1.length))
        {
          ArrayList[] arrayOfArrayList2 = new ArrayList[n + 5];
          System.arraycopy(localObject1, 0, arrayOfArrayList2, 0, localObject1.length);
          localObject1 = arrayOfArrayList2;
        }
        if (!bool2) {
          if (localObject1[n] == null) {
            localObject1[n] = new ArrayList(64);
          }
        }
        localObject1[n].add(localObject2);
        k++;
      } while (!bool1);
      if (!bool2) {
        label198:
        label203:
        if ((bool2) || (j < localObject1.length - 1))
        {
          ArrayList[] arrayOfArrayList1 = new ArrayList[j + 1];
          System.arraycopy(localObject1, 0, arrayOfArrayList1, 0, j + 1);
          return arrayOfArrayList1;
        }
      }
      return localObject1;
    }
    
    b_(mb.0 param0)
    {
      this();
    }
  }
  
  private final class c_
    implements jc
  {
    boolean i;
    boolean j;
    boolean k = true;
    boolean l;
    boolean m;
    private jc n;
    
    c_()
    {
      nb localnb = new nb();
      localnb.a(this.i);
      localnb.b(this.k);
      localnb.c(this.l);
      this.n = localnb;
    }
    
    public Iterator a(g paramg, int paramInt)
    {
      if (!ld.E) {}
      jc localjc = f() ? new rc.i_(this.n, c()) : this.n;
      return localjc.a(paramg, paramInt);
    }
    
    public Iterator b(g paramg, int paramInt)
    {
      if (!ld.E) {}
      jc localjc = f() ? new rc.i_(this.n, c()) : this.n;
      return localjc.b(paramg, paramInt);
    }
    
    boolean a()
    {
      return this.j;
    }
    
    void a(boolean paramBoolean)
    {
      if (!ld.E)
      {
        if (this.j != paramBoolean) {
          this.j = paramBoolean;
        }
      }
      else
      {
        Object localObject;
        if (this.j)
        {
          localObject = new mb.b_(mb.this, null);
          ((mb.b_)localObject).i = this.i;
          this.n = ((jc)localObject);
          if (!ld.D) {}
        }
        else
        {
          localObject = new nb();
          ((nb)localObject).a(this.i);
          ((nb)localObject).b(this.k);
          ((nb)localObject).c(this.l);
          this.n = ((jc)localObject);
        }
      }
    }
    
    boolean b()
    {
      return this.k;
    }
    
    void b(boolean paramBoolean)
    {
      this.k = paramBoolean;
      if ((ld.E) || (!this.j)) {
        ((nb)this.n).b(paramBoolean);
      }
    }
    
    boolean c()
    {
      return this.l;
    }
    
    void c(boolean paramBoolean)
    {
      this.l = paramBoolean;
      if ((ld.E) || (!this.j)) {
        ((nb)this.n).c(paramBoolean);
      }
    }
    
    boolean e()
    {
      return this.i;
    }
    
    void d(boolean paramBoolean)
    {
      boolean bool = ld.E;
      this.i = paramBoolean;
      if (!bool) {
        if (!this.j)
        {
          if (bool) {
            break label45;
          }
          ((nb)this.n).a(paramBoolean);
          if (!ld.D) {
            return;
          }
        }
      }
      label45:
      ((mb.b_)this.n).i = paramBoolean;
    }
    
    public boolean f()
    {
      return this.m;
    }
    
    public void e(boolean paramBoolean)
    {
      this.m = paramBoolean;
    }
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.j.mb

 * JD-Core Version:    0.7.0.1

 */